<template>
  <view class="button-warp" @click="onClick">
    <view class="button">
      <slot name="pictuer" class="pictuer"></slot>
      <slot></slot>
    </view>
  </view>
  <view class="min-h-[64px] w-full"></view>
</template>

<script setup lang="ts">
const emit = defineEmits(['btnClick'])

function onClick() {
  emit('btnClick')
}
// function handelEmit(){
//   uni.$emit('clickBotton')
// }
</script>

<style scoped lang="scss">
.button-warp {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  text-align: center;
  padding: 12px 15px;
  background-color: #fff;
  z-index: 200;
  .button {
    border-radius: 4px;
    opacity: 1;
    background: #56b756;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    flex-direction: row;
    gap: 10px;
  }
}
</style>
